$(document).ready( function(){
    graphics();
})
function graphics()
{
    $(function(){
        /** This code runs when everything has been loaded on the page */
        /* Inline sparklines take their values from the contents of the tag */
        $('.inlinesparkline').sparkline(); 
        /* Sparklines can also take their values from the first argument 
        passed to the sparkline() function */
        var myvalues = [10,8,5,7,4,4,1];
        $('.dynamicsparkline').sparkline(myvalues);
        /* The second argument gives options such as chart type */
        $('.dynamicbar').sparkline(myvalues, {
            type:'bar', 
            barColor: 'green'
        } );
        /* Use 'html' instead of an array of values to pass options 
        to a sparkline with data in the tag */
        $('.inlinebar').sparkline('html', {
            type:'bar', 
            barColor: 'red'
        } );
        
        $("#sparkline").sparkline([8,4,2],{
            type:'pie',
            width: '225',
            height: '225'
        });
        
        $("#barsparkline").sparkline([4,5,6], {
            type: 'bar',
            zeroAxis: false,
            barColor: '#ff00ff',
            negBarColor: '#f04040 ',
            zeroColor: '#ffffff',
            height: '250',
            barWidth: 26
        });
        
        
        
        
    
    });
}
